{
  "properties" : { },
  "id" : "copy1737981732312d31603",
  "script" : null,
  "groupId" : "36128bf377a74a6f97dd76c88edaaef0",
  "name" : "执行任务(识别图片)",
  "createTime" : null,
  "updateTime" : 1738742493091,
  "lock" : null,
  "createBy" : "管理员",
  "updateBy" : "可辉",
  "path" : "task_ocr",
  "method" : "GET",
  "parameters" : [ ],
  "options" : [ ],
  "requestBody" : "",
  "headers" : [ ],
  "paths" : [ ],
  "responseBody" : "{\n    \"code\": 200,\n    \"msg\": \"success\",\n    \"data\": 0\n}",
  "description" : null,
  "requestBodyDefinition" : null,
  "responseBodyDefinition" : null
}
================================
import com.wiwf.model.task.bean.TaskerCommand;
import 'com.wiwf.model.task.service.TaskExecService' as taskExecService;
import 'com.wiwf.model.task.service.TaskOutHandlerService' as taskOutHandlerService;

var isWin = System.getProperty("os.name").startsWith("Windows");
var cmd = """
    "C:/Program\ Files/Tesseract-OCR/tesseract.exe" "D:/tmpimg/xxxxxxxxxx.jpg" "D:/output" -l eng
""";
TaskerCommand createTasker = taskExecService.createTasker("1001", cmd, taskOutHandlerService);

createTasker.getProcess().waitFor();

taskExecService.stopTasker(createTasker); 

return 0;